package com.sunchangpeng.wechat.core.utils;

import java.io.UnsupportedEncodingException;
import java.net.URLEncoder;

public class URLUtils {
    public static String encode(String str) {
        try {
            return URLEncoder.encode(str, "UTF-8");
        } catch (UnsupportedEncodingException e) {
            //never reach here
            throw new RuntimeException(e);
        }
    }
}
